/*
 * @Author: typ
 * @Date: 2025-02-26 09:20:39
 * @LastEditors: typ
 * @LastEditTime: 2025-02-27 08:27:36
 * @FilePath: /onemap/src/api/layer.js
 * @Description: 
 */
import request from "@/utils/request";

// 获取图层类别
export function getLayerType(params) {
  return request({
    url: "yzt/catalog/list",
    method: "get",
    params
  });
}

// 修改默认图层
export function updateDefaultLayer(data) {
  return request({
    url: "yzt/catalog/browse/default",
    method: "put",
    data
  });
}

// 获取图层列表
export function getLayerTree(params) {
  return request({
    url: "yzt/catalog/tree",
    method: "get",
    params
  });
}

// 获取图层详情
export function getLayerDetail(layerId) {
  return request({
    url: `yzt/layer/${layerId}`,
    method: "get"
  });
}